package com.qhit.service.impl;

import com.qhit.service.GoodsService;
import com.qhit.dao.GoodsMappper;
import com.qhit.pojo.Goods;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.HashMap;
import java.util.List;

@Service
public class GoodsServiceImpl implements GoodsService {
    @Autowired
    private GoodsMappper goodsMapper;
    @Override
    public List<Goods> getList(HashMap hashMap) {
        return goodsMapper.getList(hashMap);

    }

    @Override
    public List<Goods> getList2() {
        return goodsMapper.getList2();
    }

    @Override
    public Long getListCount(HashMap hashMap) {
        return goodsMapper.getListCount(hashMap);
    }

    @Override
    public int add(Goods goods) {
        return goodsMapper.add(goods);
    }

    @Override
    public Goods getGoodsById(Integer id) {
        return goodsMapper.getGoodsById(id);
    }

    @Override
    public int edit(Goods goods) {
        return goodsMapper.edit(goods);
    }

    @Override
    public int delete(Integer id) {
        return goodsMapper.delete(id);
    }


}
